<%@page contentType="text/html;charset=utf-8" %><%@taglib prefix="s" uri="/struts-tags" %>login.jsp
<script type="text/javascript">
function login_check()
{
    var id = document.getElementById("id").value;
    var password = document.getElementById("password").value;
    var verify = document.getElementById("verify").value;

    if (id == null || id == ""
        || password == null || password == ""
        || verify == null || verify == "")
    {
        alert("输入无效！");
        return;
    }

    var url      = "sl/login.do";
    var content  = "id=" + id
                 + "&password=" + password
                 + "&verifyCode=" + verify; ;  
    var objectid = "container";
    sendXMLHttpRequest(url, content, objectid);    
}

function login_reset()
{
    document.getElementById("id").value = "";
    document.getElementById("password").value = "";
}
</script>
</script>
<center>
<table>
<tr valign="top">
    <td height="100" ></td>
</tr>
<tr valign="middle">
<td>
<table width="1002" border="0" align="center" cellpadding="0" cellspacing="0">
  <tr>
    <td width="201">&nbsp;</td>
    <td width="600" height="360" align="center" background="images/bg_mob.png">
      <table width="400" border="0" cellspacing="0" cellpadding="0">
        <tr>
          <td height="20" colspan="3"></td>
        </tr>
        <tr>
          <td height="30" align="center" colspan="3"><font color="red"><s:actionerror/></font>  </td>
        </tr>
        <tr>
          <td width="35%" height="30" align="right" class="table_dot">用户名：</td>
          <td  height="30" align="left" class="table_dot" colspan="2">
          <input name="id" id="id" type="text" class="loginInput" 
                 onkeydown="javascript:if(event.keyCode==13){document.getElementById('password').focus();}"/></td>
        </tr>
        <tr>
          <td height="30" align="right" class="table_dot">密　码：</td>
          <td height="30" align="left" class="table_dot" colspan="2">
          <input name="password" id="password" type="password" class="loginInput" 
                 onkeydown="javascript:if(event.keyCode==13){document.getElementById('verify').focus();}" />
          </td>
        </tr>
        <tr>
        <td height="30" align="right" class="table_dot">验证码：</td>
          <td height="30" width="25%" align="left" class="table_dot">
              <input name="verify" id ="verify" type="text" size = "8" class="loginInput" 
              onkeydown="javascript:if(event.keyCode==13){login_check();}"/>
          </td>
          <td height="30" align="left" valign="middle" class="table_dot">
          	<img alt="看不清楚?换一张" title="看不清楚?换一张" src="./codepicservlet" style="cursor: pointer;" 
               onclick= "this.src='./codepicservlet?s='+Math.random()"/>
          </td>
        </tr>
        <tr>
          <td height="30" align="center" class="table_dot" colspan="3">
          <button id="btn1" dojoType="dijit.form.Button" 
                  onclick="login_check();">登 录</button>
          &nbsp;&nbsp;
          <button id="btn2" dojoType="dijit.form.Button" 
                  onclick="login_reset();">重 置</button></td>
        </tr>
      </table>
    </td>
    <td width="201">&nbsp;</td>
  </tr>
</table>
</td>
</tr>
<tr valign="bottom">
<td>
<%@include file="../footer.jsp" %>
</td>
</tr>
</table>
</center>
